using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting;
using UnityEngine;

public class BlanderChengJie : TargetCardItem
{
    protected override void Start()
    {
        base.Start();
        damageCount = int.Parse(data["Arg0"]);
    }

    protected override void DealCardUse()
    {
        AudioManager.Instance.PlayEffect("daji");

        int val = damageCount;

        EnemyManager.Instance.DealEnemyHurt(hitEnemy, val);

        if (hitEnemy.TryGetComponent<YiShangBuff>(out _))
        {
            hitEnemy.GetComponent<YiShangBuff>().CountUp(2);
        }
        else
        {
            hitEnemy.AddComponent<YiShangBuff>();
            hitEnemy.GetComponent<YiShangBuff>().SetStartCount(2);
        }
    }
}
